package io.demo02;


import java.io.BufferedWriter;
import java.io.FileWriter;
import java.io.IOException;

/**
 * @author cyt
 * @create 2020-02-25 14:41
 */
public class BufferedWrite {

    public static void main(String[] args) throws IOException {
        // 定义
        BufferedWriter bufferedWriter = null;
        try {
            bufferedWriter = new BufferedWriter(new FileWriter("e://io_writer.txt", true), 2014 * 8);
            bufferedWriter.write("buffer");
            bufferedWriter.newLine();
            bufferedWriter.flush();
            System.out.println("ok");
        } catch (IOException e) {
            e.printStackTrace();
        }
        bufferedWriter.close();

    }
}
